//
//  SettingInfoTools.m
//  TimeToCoin
//
//  Created by 1-Mac on 2018/8/1.
//  Copyright © 2018年 QuanLi Technology Limited. All rights reserved.
//

#import "SettingInfoTools.h"

@implementation SettingInfoTools


/**
 判断是否第一次运行

 @return 返回是否第一次运行
 */
+ (BOOL)isFirstRunning
{
    
    NSNumber *number = [[NSUserDefaults standardUserDefaults]objectForKey:FirstRuning];
    
    
    
    if ([number boolValue] == YES) {
        
        
        return NO;
    }else
    {
        
        return YES;
        
        
    }
}

/**
 保存运行后的结果（PS: 第一次运行后的结果）
 */
+ (void)recordFirstRunning
{
    NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
    
    [defaults setObject:[NSNumber numberWithBool:YES] forKey:FirstRuning];
    
    [defaults synchronize];
    
}

@end
